package com.sgb.kjwl.model.entity.self;

import android.text.TextUtils;

import com.sgb.kjwl.utils.NumberUtil;

/**
 * Describe:
 * Author:  yangLei
 * Date:    2021/10/14
 */
public class ProCarInfoEntity {
    //车辆编号
    private String no;
    //类型 1 自营 2 挂靠
    private String type;
    //额定载重
    private Float weight;
    private String carLenName;
    private String carNumber;
    private String carTypeName;
    private String imgUrl;

    public String getImgUrl() {
        return imgUrl;
    }

    public void setImgUrl(String imgUrl) {
        this.imgUrl = imgUrl;
    }

    public String getCarLenName() {
        return carLenName;
    }

    public void setCarLenName(String carLenName) {
        this.carLenName = carLenName;
    }

    public String getCarNumber() {
        return carNumber;
    }

    public void setCarNumber(String carNumber) {
        this.carNumber = carNumber;
    }

    public String getCarTypeName() {
        return carTypeName;
    }

    public void setCarTypeName(String carTypeName) {
        this.carTypeName = carTypeName;
    }

    public String getNo() {
        return no;
    }

    public void setNo(String no) {
        this.no = no;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public Float getWeight() {
        return weight;
    }

    public void setWeight(Float weight) {
        this.weight = weight;
    }

    public String getCarInfo() {
        StringBuilder info = new StringBuilder("");
        if (!TextUtils.isEmpty(carTypeName)) {
            info.append(carTypeName + "/");
        }
        if (!TextUtils.isEmpty(carLenName)) {
            info.append("长" + carLenName + "/");
        }
        if (weight > 0) {
            info.append(NumberUtil.trim0(weight) + "吨");
        }
        return info.toString();
    }
}
